home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / prog / uniforth.zip / VEDITOR.FTH < prev    next >
Text File  |  1985-08-20  |  10KB  |  1 lines

  1. *********** CUSTOMIZATION SCREENS FOR VIDEO EDITOR *************                                                                The video editor is preconfigured for the IBM-PC.               We've included customize screens for three popular terminal     types.  One should match your terminal closely enough that      you can customize the editor.                                                                                                   The cursor key/menu screens enable you to use any key           pattern you wish with the editor  (for example, set it up       ala Wordstar or to use function keys).                                                                                          Example:  customize for VT-100, change menu.                                                                                       3 LOAD  6 LOAD                                                                                                               try it, then sysgen.                                            ( Terminal dependent characteristics -- ADM5)                   EDITOR DEFINITIONS                                              : (HOME)  ( -- ..move cursor to upleft)  30 EMIT ;              : (PAGE)  ( -- ..clear screen)  26 EMIT ;                       : (BRIT)  ( norm video intensity)  27 EMIT 40 EMIT ;            : (DIM)   ( half intensity)  27 EMIT 41 EMIT ;                  : (GOTO)  ( xval yval --- ...goto x,y wrt upper left)              27 EMIT 61 EMIT 0 MAX 23 MIN 32 + EMIT                          0 MAX 79 MIN 32 + EMIT ;                                     ' (PAGE)  $PAGE !      ' (GOTO) $GOTO !                         ' (HOME)  $HOME !      ' (BRIT) $BRIT !                         ' (DIM)   $DIM !       ' NOOP   $INIT !                         FORTH DEFINITIONS                                               ;S                                                                                                                                                                                              ( Terminal dependent characteristics -- H-19)                   EDITOR DEFINITIONS                                              : (HOME)  ( -- move cursor to upper left)  27 EMIT 72 EMIT ;    : (PAGE)  ( -- clear screen)  27 EMIT 69 EMIT ;                 : (GOTO)  ( xval yval --- ...goto x,y wrt upper left)              27 EMIT 89 EMIT 0 MAX 23 MIN 32 + EMIT                          0 MAX 79 MIN 32 + EMIT ;                                     ' (PAGE)  $PAGE !      ' (GOTO) $GOTO !                         ' (HOME)  $HOME !      ' NOOP   $BRIT !                         ' NOOP    $DIM !       ' NOOP   $INIT !                         FORTH DEFINITIONS                                               ;S                                                                                                                                                                                                                                                                                                                              ( Terminal dependent characteristics -- VT-100)                 EDITOR DEFINITIONS                                              : Z.R  ( n1 n2 --- ...print n1 in n2 fields, zero filled)          >R S->D SWAP OVER DABS <# R> 0 DO # LOOP SIGN #> TYPE ;      : CSI  ( control sequence introducter, ESC [)                      27 EMIT 91 EMIT ;                                            : (HOME)  ( -- move to upper left)  CSI 72 EMIT ;               : (PAGE)  ( -- clear screen)  CSI 50 EMIT 74 EMIT ;             : (BRIT)  ( -- full intensity)  CSI 49 EMIT 109 EMIT ;          : (DIM)   ( -- half intensity) CSI 48 EMIT 109 EMIT ;           : (GOTO)  ( xval yval --- ...goto x,y wrt upper left)              CSI 1+ 2 Z.R 59 EMIT 1+ 2 Z.R 72 EMIT ;                      -->                                                                                                                                                                                                                                                             ( Terminal dependent characteristics -- VT-100 cont'd)          ' (PAGE)  $PAGE !      ' (GOTO) $GOTO !                         ' (HOME)  $HOME !      ' NOOP   $BRIT !                         ' NOOP    $DIM !       ' NOOP   $INIT !                         FORTH DEFINITIONS                                               ;S                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ;S                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ( UNIFORTH-style cursor control keys -- 1    123183 aah)  HEX   EDITOR                                                          1B ' V.FLSH >BODY !  ( end edit with flush)                     18 ' V.ABRT >BODY !  ( end edit w/abort, loose last block)      0E ' V.NEXT >BODY !  ( next block)                              10 ' V.OLD  >BODY !  ( old block)                               0A ' V.JMP  >BODY !  ( jump block)                              09 ' V.INS  >BODY !  ( insert toggle)                           02 ' V.BAK  >BODY !  ( backward 1 word)                         06 ' V.FWD  >BODY !  ( forward 1 word)                          7F ' V.B4   >BODY !  ( del char b4 cursor)                      11 ' V.AT   >BODY !  ( del char at cursor)                      13 ' V.STR  >BODY !  ( string mode)                             17 ' V.BL   >BODY !  ( insert blank)                            1A ' V.DELW >BODY !  ( delete word)                             DECIMAL -->                                                     ( UNIFORTH-style cursor control keys -- 2    123183 aah)  HEX   01 ' V.ADDL  >BODY !  ( add blank line)                         0B ' V.DELL  >BODY !  ( delete line)                            14 ' V.TRAN  >BODY !  ( trans line to stack)                    19 ' V.YANK  >BODY !  ( yank line from stack)                   16 ' V.CEOL  >BODY !  ( clear to end-of-line)                   0C ' V.CURL  >BODY !  ( cursor left)                            08 ' V.CURLA >BODY !  ( also cursor left)                       12 ' V.CURR  >BODY !  ( cursor right)                           04 ' V.CURD  >BODY !  ( cursor down)                            15 ' V.CURU  >BODY !  ( cursor up)                              0D ' V.NEWL  >BODY !  ( move to new line)                       07 ' V.HOME  >BODY !  ( home cursor)                            05 ' V.EOL   >BODY !  ( move to end-of-line)                    0F ' V.PREV  >BODY !  ( move to previous line)                  DECIMAL -->                                                     ( UNIFORTH-syle menu                    123183 aah)             BLK @ BLOCK 128 + MENARR 5 64 * CMOVE FORTH ;S  fill menu array ^G=gohome  ^L=left  ^R=right  ^U=up  ^D=down ^F=fwd, ^B=bak tab ^O=old line  ^E=end line  CR=nxt line  ^V=void->EOL ^W=wrt blank^K=kill line  ^A=add line  ^T=trans to, ^Y=yank from line stack DEL=del b4, ^Q=del at curs ^Z=zap wd  ^I=insert, ^S=string modesExits:  ESC=flush, ^X=noflush    Block: ^P=prev, ^N=next ^J=jump                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ;S